package org.dey.controller;

import org.dey.pojo.PageVo;
import org.dey.pojo.Risk;
import org.dey.service.RiskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;


@RestController
public class RiskController {
    @Autowired
    RiskService riskService;

    @PostMapping("queryR.do/{pageNum}/{pagesize}")
    public PageVo<Risk> queryAm(@RequestBody Risk risk,
                                @PathVariable Integer pageNum,
                                @PathVariable Integer pagesize){
        PageVo<Risk> list = riskService.queryR(risk, pageNum, pagesize);
        return list;
    }


}
